#include <xp/bas/ctype_unicode.h>
#include <wctype.h>
#include <locale.h>
#include <wchar.h>
#include <stdio.h>

int xp_main ()
{
	int i;

	printf ("%s\n", setlocale (LC_ALL, ""));

	for (i = 0; i < 0xffff; i++) {
		//if (iswalpha (i) != xp_unicode_isalpha (i)) 
		//	printf ("%d %d/%d\n", i, iswalpha(i), xp_unicode_isalpha(i));
		if ((iswalpha(i) && !xp_unicode_isalpha(i)) ||
		    (!iswalpha(i) && xp_unicode_isalpha(i))) {
			printf ("0x%04X %d/%d\n", i, iswalpha(i), xp_unicode_isalpha(i));
		}
		//printf ("%d %d\n", i, xp_unicode_isalpha(i));
	}

	for (i = 'A'; i < 'Z'; i++) {
		printf ("%lc, %lc\n", i, xp_unicode_tolower(i));
	}

	for (i = 'a'; i < 'z'; i++) {
		printf ("%lc, %lc\n", i, xp_unicode_toupper(i));
	}

	return 0;
}
